<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.5"/>
<title>aiengine: xaiesim.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="HTML_custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="xlogo_bg.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">aiengine
   </div>
   <div id="projectbrief">Vitis Drivers API Documentation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Overview</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="globals.html"><span>APIs</span></a></li>
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('xaiesim_8c.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">xaiesim.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Overview</h2>
<div class="textblock"><p>This file contains the low level layer interface to the AIE simulator. </p>
<pre>
MODIFICATION HISTORY:</pre><pre>Ver   Who     Date     Changes
</p>
<hr/>
<p>
1.0  Naresh  04/06/2018  Initial creation
1.1  Naresh  04/10/2018  Added the API XAieSim_Init
1.2  Naresh  04/18/2018  Modified workaround for CRVO#1696/CR#999680 to extend
                         it to all types of registers and also for all the
                         tiles i.e., not just specific to PL interface regs
1.3  Naresh  05/07/2018  Fixed CR#1001816
1.4  Naresh  05/23/2018  Updated code to fix CR#999693 and removed the static
                         data structure allocation for the registers to be
                         monitored, instead added dynamic memory allocation.
1.5  Naresh  06/13/2018  Fixed CR#1003905, CR#1004494
1.6  Naresh  07/11/2018  Updated copyright info
1.7  Hyun    10/16/2018  Added XAieSim_IO_Funcs to support dynamic backend
                         select at runtime as a part of CDO generation
                         support. CR-1012480
1.8  Nishad  12/05/2018  Renamed ME attributes to AIE
1.9  Hyun    01/08/2018  Add the MaskPoll
2.0  Hyun    04/05/2018  NPI support
2.1  Tejus   04/23/2020  Fix unsigned int overflow.
</pre> </div><table class="memberdecls">
<tr class="memitem:a8fdd48e30504296b3dffd41997126667"><td class="memItemLeft" align="right" valign="top">uint32&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a8fdd48e30504296b3dffd41997126667">XAieSim_Read32</a> (uint64_t Addr)</td></tr>
<tr class="memdesc:a8fdd48e30504296b3dffd41997126667"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to read 32bit data from the specified address.  <a href="#a8fdd48e30504296b3dffd41997126667">More...</a><br/></td></tr>
<tr class="separator:a8fdd48e30504296b3dffd41997126667"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29b0d1d8b69627f1bee8898932f1d5e3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a29b0d1d8b69627f1bee8898932f1d5e3">XAieSim_Read128</a> (uint64_t Addr, uint32 *Data)</td></tr>
<tr class="memdesc:a29b0d1d8b69627f1bee8898932f1d5e3"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to read 128b data from the specified address.  <a href="#a29b0d1d8b69627f1bee8898932f1d5e3">More...</a><br/></td></tr>
<tr class="separator:a29b0d1d8b69627f1bee8898932f1d5e3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2188251ed58e7c9364da7271695ed916"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a2188251ed58e7c9364da7271695ed916">XAieSim_Write32</a> (uint64_t Addr, uint32 Data)</td></tr>
<tr class="memdesc:a2188251ed58e7c9364da7271695ed916"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to write 32bit data to the specified address.  <a href="#a2188251ed58e7c9364da7271695ed916">More...</a><br/></td></tr>
<tr class="separator:a2188251ed58e7c9364da7271695ed916"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a34b10b352d1c2bd8985a1436a8bc5e97"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a34b10b352d1c2bd8985a1436a8bc5e97">XAieSim_MaskWrite32</a> (uint64_t Addr, uint32 Mask, uint32 Data)</td></tr>
<tr class="memdesc:a34b10b352d1c2bd8985a1436a8bc5e97"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to mask-write 32bit data to the address.  <a href="#a34b10b352d1c2bd8985a1436a8bc5e97">More...</a><br/></td></tr>
<tr class="separator:a34b10b352d1c2bd8985a1436a8bc5e97"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9f4547debce2a6d307fc0b3e3c636b00"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a9f4547debce2a6d307fc0b3e3c636b00">XAieSim_Write128</a> (uint64_t Addr, uint32 *Data)</td></tr>
<tr class="memdesc:a9f4547debce2a6d307fc0b3e3c636b00"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to write 128bit data to the specified address.  <a href="#a9f4547debce2a6d307fc0b3e3c636b00">More...</a><br/></td></tr>
<tr class="separator:a9f4547debce2a6d307fc0b3e3c636b00"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aafa63ad23c4fabcd69550afdd5bc997d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#aafa63ad23c4fabcd69550afdd5bc997d">XAieSim_WriteCmd</a> (uint8 Command, uint8 ColId, uint8 RowId, uint32 CmdWd0, uint32 CmdWd1, uint8 *CmdStr)</td></tr>
<tr class="memdesc:aafa63ad23c4fabcd69550afdd5bc997d"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to write 128bit data to the specified address.  <a href="#aafa63ad23c4fabcd69550afdd5bc997d">More...</a><br/></td></tr>
<tr class="separator:aafa63ad23c4fabcd69550afdd5bc997d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a80ae4affbfb62d6430687bfe8707c383"><td class="memItemLeft" align="right" valign="top">uint32&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a80ae4affbfb62d6430687bfe8707c383">XAieSim_MaskPoll</a> (uint64_t Addr, uint32 Mask, uint32 Value, uint32 TimeOutUs)</td></tr>
<tr class="memdesc:a80ae4affbfb62d6430687bfe8707c383"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the IO function to poll until the value at the address to be given masked value.  <a href="#a80ae4affbfb62d6430687bfe8707c383">More...</a><br/></td></tr>
<tr class="separator:a80ae4affbfb62d6430687bfe8707c383"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a568786c9ca88f7cc85e58fb835c7ff55"><td class="memItemLeft" align="right" valign="top">uint8&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a568786c9ca88f7cc85e58fb835c7ff55">XAieSim_SetIOMode</a> (uint8 Mode)</td></tr>
<tr class="memdesc:a568786c9ca88f7cc85e58fb835c7ff55"><td class="mdescLeft">&#160;</td><td class="mdescRight">This API sets the IO mode and switches to available backend for IO operations.  <a href="#a568786c9ca88f7cc85e58fb835c7ff55">More...</a><br/></td></tr>
<tr class="separator:a568786c9ca88f7cc85e58fb835c7ff55"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad607fc08bc84434e9747155e5ada9328"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#ad607fc08bc84434e9747155e5ada9328">XAieSim_Init</a> (uint8 NumCols, uint8 NumRows)</td></tr>
<tr class="memdesc:ad607fc08bc84434e9747155e5ada9328"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the init routine to enable AIE sim workarounds.  <a href="#ad607fc08bc84434e9747155e5ada9328">More...</a><br/></td></tr>
<tr class="separator:ad607fc08bc84434e9747155e5ada9328"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7e27e0af095370d54f3fcc96dba0af6c"><td class="memItemLeft" align="right" valign="top">uint32&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a7e27e0af095370d54f3fcc96dba0af6c">XAieSim_NPIRead32</a> (uint64_t Addr)</td></tr>
<tr class="memdesc:a7e27e0af095370d54f3fcc96dba0af6c"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to read 32bit data from the NPI space.  <a href="#a7e27e0af095370d54f3fcc96dba0af6c">More...</a><br/></td></tr>
<tr class="separator:a7e27e0af095370d54f3fcc96dba0af6c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ace1a443fec705f55a7ea09f3a244ba60"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#ace1a443fec705f55a7ea09f3a244ba60">XAieSim_NPIWrite32</a> (uint64_t Addr, uint32 Data)</td></tr>
<tr class="memdesc:ace1a443fec705f55a7ea09f3a244ba60"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to write 32bit data to the NPI space.  <a href="#ace1a443fec705f55a7ea09f3a244ba60">More...</a><br/></td></tr>
<tr class="separator:ace1a443fec705f55a7ea09f3a244ba60"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a79a320d304972e9eefe822c320a01b65"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a79a320d304972e9eefe822c320a01b65">XAieSim_NPIMaskWrite32</a> (uint64_t Addr, uint32 Mask, uint32 Data)</td></tr>
<tr class="memdesc:a79a320d304972e9eefe822c320a01b65"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the memory IO function to mask-write 32bit data to the NPI space.  <a href="#a79a320d304972e9eefe822c320a01b65">More...</a><br/></td></tr>
<tr class="separator:a79a320d304972e9eefe822c320a01b65"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1e7fd7b9d3ffb6a2c544d63678709dcb"><td class="memItemLeft" align="right" valign="top">uint32&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="xaiesim_8c.html#a1e7fd7b9d3ffb6a2c544d63678709dcb">XAieSim_NPIMaskPoll</a> (uint64_t Addr, uint32 Mask, uint32 Value, uint32 TimeOutUs)</td></tr>
<tr class="memdesc:a1e7fd7b9d3ffb6a2c544d63678709dcb"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is the IO function to poll until the value at the NPI address space to be given masked value.  <a href="#a1e7fd7b9d3ffb6a2c544d63678709dcb">More...</a><br/></td></tr>
<tr class="separator:a1e7fd7b9d3ffb6a2c544d63678709dcb"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="ad607fc08bc84434e9747155e5ada9328"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_Init </td>
          <td>(</td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>NumCols</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>NumRows</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the init routine to enable AIE sim workarounds. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">NumCols,:</td><td>Number of columns. </td></tr>
    <tr><td class="paramname">NumRows,:</td><td>Number of rows.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xsock__clitest_8c.html#a0ddf1224851353fc92bfbff6f499fa97">main()</a>.</p>

</div>
</div>
<a class="anchor" id="a80ae4affbfb62d6430687bfe8707c383"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32 XAieSim_MaskPoll </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Mask</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>TimeOutUs</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the IO function to poll until the value at the address to be given masked value. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Mask,:</td><td>Mask to be applied to read data. </td></tr>
    <tr><td class="paramname">Value,:</td><td>The expected value </td></tr>
    <tr><td class="paramname">TimeOutUs,:</td><td>Minimum timeout in usec.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XAIESIM_SUCCESS if successful, else XAIESIM_FAILURE.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#ae24a68d49a75f90bb1d7420bf61cfd3d">XAieLib_MaskPoll()</a>.</p>

</div>
</div>
<a class="anchor" id="a34b10b352d1c2bd8985a1436a8bc5e97"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_MaskWrite32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Mask</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to mask-write 32bit data to the address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Mask,:</td><td>Mask to be applied. </td></tr>
    <tr><td class="paramname">Data,:</td><td>32-bit data to be written.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#aea8f2e8219b0446aed5136335954632f">XAieLib_MaskWrite32()</a>.</p>

</div>
</div>
<a class="anchor" id="a1e7fd7b9d3ffb6a2c544d63678709dcb"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32 XAieSim_NPIMaskPoll </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Mask</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>TimeOutUs</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the IO function to poll until the value at the NPI address space to be given masked value. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Mask,:</td><td>Mask to be applied to read data. </td></tr>
    <tr><td class="paramname">Value,:</td><td>The expected value </td></tr>
    <tr><td class="paramname">TimeOutUs,:</td><td>Minimum timeout in usec.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XAIESIM_SUCCESS if successful, else XAIESIM_FAILURE.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#ae034043fa2450cb0c690a41fe66f6ca9">XAieLib_NPIMaskPoll()</a>.</p>

</div>
</div>
<a class="anchor" id="a79a320d304972e9eefe822c320a01b65"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_NPIMaskWrite32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Mask</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to mask-write 32bit data to the NPI space. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Mask,:</td><td>Mask to be applied. </td></tr>
    <tr><td class="paramname">Data,:</td><td>32-bit data to be written.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8c.html#ad0a0197362dc2f915f5f21684760bd0f">XAieLib_NPIMaskWrite32()</a>.</p>

</div>
</div>
<a class="anchor" id="a7e27e0af095370d54f3fcc96dba0af6c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32 XAieSim_NPIRead32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to read 32bit data from the NPI space. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to read from.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>32-bit read value.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#a479677997332b0bffab48ac25ccf9159">XAieLib_NPIRead32()</a>.</p>

</div>
</div>
<a class="anchor" id="ace1a443fec705f55a7ea09f3a244ba60"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_NPIWrite32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to write 32bit data to the NPI space. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Data,:</td><td>32-bit data to be written.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#a2fd1a6b12446eb8fd0b3172ecc8d5a1f">XAieLib_NPIWrite32()</a>.</p>

</div>
</div>
<a class="anchor" id="a29b0d1d8b69627f1bee8898932f1d5e3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_Read128 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32 *&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to read 128b data from the specified address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to read from. </td></tr>
    <tr><td class="paramname">Data,:</td><td>Pointer to the 128-bit buffer to store the read data.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

</div>
</div>
<a class="anchor" id="a8fdd48e30504296b3dffd41997126667"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32 XAieSim_Read32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to read 32bit data from the specified address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to read from.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>32-bit read value.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#a6c4151c74c8c8c287d2f2d7e8b2c3308">XAieLib_Read128()</a>, and <a class="el" href="xaielib_8h.html#a820be016043929d0c727ca1ebea73733">XAieLib_Read32()</a>.</p>

</div>
</div>
<a class="anchor" id="a568786c9ca88f7cc85e58fb835c7ff55"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8 XAieSim_SetIOMode </td>
          <td>(</td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>Mode</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This API sets the IO mode and switches to available backend for IO operations. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Mode,:</td><td>IO mode. Should be XAIESIM_IO_MODE_* in <a class="el" href="xaiesim_8h.html" title="This file contains the generic definitions for the AIE simulator interface. ">xaiesim.h</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>XAIESIM_SUCCESS on success.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

</div>
</div>
<a class="anchor" id="a9f4547debce2a6d307fc0b3e3c636b00"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_Write128 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32 *&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to write 128bit data to the specified address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Data,:</td><td>Pointer to the 128-bit data buffer.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#a9c957fb3e99baea854f371426fbab9d6">XAieLib_Write128()</a>.</p>

</div>
</div>
<a class="anchor" id="a2188251ed58e7c9364da7271695ed916"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_Write32 </td>
          <td>(</td>
          <td class="paramtype">uint64_t&#160;</td>
          <td class="paramname"><em>Addr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>Data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to write 32bit data to the specified address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Data,:</td><td>32-bit data to be written.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#aeab7b9a775763561f4b5ffe900b448ce">XAieLib_Write32()</a>.</p>

</div>
</div>
<a class="anchor" id="aafa63ad23c4fabcd69550afdd5bc997d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XAieSim_WriteCmd </td>
          <td>(</td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>Command</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>ColId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8&#160;</td>
          <td class="paramname"><em>RowId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>CmdWd0</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32&#160;</td>
          <td class="paramname"><em>CmdWd1</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8 *&#160;</td>
          <td class="paramname"><em>CmdStr</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This is the memory IO function to write 128bit data to the specified address. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">Addr,:</td><td>Address to write to. </td></tr>
    <tr><td class="paramname">Data,:</td><td>Pointer to the 128-bit data buffer.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>Referenced by <a class="el" href="xaielib_8h.html#a0785309bf71fa965f2f98a8c0aeb9503">XAieLib_WriteCmd()</a>, <a class="el" href="xaiesim__elfload_8c.html#a1291dc3091cf4d366aa7dc7e8eaf3063">XAieSim_LoadElf()</a>, and <a class="el" href="xaiesim__elfload_8c.html#a9201c2f1d8dede27db5ec411219fac39">XAieSim_LoadSymbols()</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
	<p class="footer">&copy; Copyright 2015-2022 Xilinx, Inc. All Rights Reserved.</p>
	<p class="footer">&copy; Copyright 2022-2023 Advanced Micro Devices, Inc. All Rights Reserved.</p>
</div>
</body>
</html>
